package com.empire.module.sporttery.dal.mysql.football500firstbuy;

import java.util.*;

import com.empire.framework.common.pojo.PageResult;
import com.empire.framework.mybatis.core.query.LambdaQueryWrapperX;
import com.empire.framework.mybatis.core.mapper.BaseMapperX;
import com.empire.module.sporttery.dal.dataobject.football500firstbuy.Football500FirstBuyDO;
import org.apache.ibatis.annotations.Mapper;
import com.empire.module.sporttery.controller.admin.football500firstbuy.vo.*;

/**
 * 500wan 必发大额交易明细 Mapper
 *
 * @author 无敌仙人
 */
@Mapper
public interface Football500FirstBuyMapper extends BaseMapperX<Football500FirstBuyDO> {

    default PageResult<Football500FirstBuyDO> selectPage(Football500FirstBuyPageReqVO reqVO) {
        return selectPage(reqVO, new LambdaQueryWrapperX<Football500FirstBuyDO>()
                .eqIfPresent(Football500FirstBuyDO::getMatchId, reqVO.getMatchId())
                .eqIfPresent(Football500FirstBuyDO::getTeam, reqVO.getTeam())
                .eqIfPresent(Football500FirstBuyDO::getBfProperty, reqVO.getBfProperty())
                .eqIfPresent(Football500FirstBuyDO::getSeller, reqVO.getSeller())
                .betweenIfPresent(Football500FirstBuyDO::getTime, reqVO.getTime())
                .eqIfPresent(Football500FirstBuyDO::getRate, reqVO.getRate())
                .orderByDesc(Football500FirstBuyDO::getId));
    }

}